3.9.24 \(\int \frac {7+3 x}{8+6 x+x^2} \, dx\)

Optimal. Leaf size=17 \[ \frac {1}{2} \log (x+2)+\frac {5}{2} \log (x+4) \]

________________________________________________________________________________________

Rubi [A]  time = 0.00, antiderivative size = 17, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 2, integrand size = 16, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.125, Rules used = {632, 31} \begin {gather*} \frac {1}{2} \log (x+2)+\frac {5}{2} \log (x+4) \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(7 + 3*x)/(8 + 6*x + x^2),x]

[Out]

Log[2 + x]/2 + (5*Log[4 + x])/2

Rule 31

Int[((a_) + (b_.)*(x_))^(-1), x_Symbol] :> Simp[Log[RemoveContent[a + b*x, x]]/b, x] /; FreeQ[{a, b}, x]

Rule 632

Int[((d_.) + (e_.)*(x_))/((a_) + (b_.)*(x_) + (c_.)*(x_)^2), x_Symbol] :> With[{q = Rt[b^2 - 4*a*c, 2]}, Dist[
(c*d - e*(b/2 - q/2))/q, Int[1/(b/2 - q/2 + c*x), x], x] - Dist[(c*d - e*(b/2 + q/2))/q, Int[1/(b/2 + q/2 + c*
x), x], x]] /; FreeQ[{a, b, c, d, e}, x] && NeQ[2*c*d - b*e, 0] && NeQ[b^2 - 4*a*c, 0] && NiceSqrtQ[b^2 - 4*a*
c]

Rubi steps

\begin {align*} \int \frac {7+3 x}{8+6 x+x^2} \, dx &=\frac {1}{2} \int \frac {1}{2+x} \, dx+\frac {5}{2} \int \frac {1}{4+x} \, dx\\ &=\frac {1}{2} \log (2+x)+\frac {5}{2} \log (4+x)\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.00, size = 17, normalized size = 1.00 \begin {gather*} \frac {1}{2} \log (x+2)+\frac {5}{2} \log (x+4) \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(7 + 3*x)/(8 + 6*x + x^2),x]

[Out]

Log[2 + x]/2 + (5*Log[4 + x])/2

________________________________________________________________________________________

IntegrateAlgebraic [F]  time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {7+3 x}{8+6 x+x^2} \, dx \end {gather*}

Verification is not applicable to the result.

[In]

IntegrateAlgebraic[(7 + 3*x)/(8 + 6*x + x^2),x]

[Out]

IntegrateAlgebraic[(7 + 3*x)/(8 + 6*x + x^2), x]

________________________________________________________________________________________

fricas [A]  time = 0.39, size = 13, normalized size = 0.76 \begin {gather*} \frac {5}{2} \, \log \left (x + 4\right ) + \frac {1}{2} \, \log \left (x + 2\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((7+3*x)/(x^2+6*x+8),x, algorithm="fricas")

[Out]

5/2*log(x + 4) + 1/2*log(x + 2)

________________________________________________________________________________________

giac [A]  time = 0.15, size = 15, normalized size = 0.88 \begin {gather*} \frac {5}{2} \, \log \left ({\left | x + 4 \right |}\right ) + \frac {1}{2} \, \log \left ({\left | x + 2 \right |}\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((7+3*x)/(x^2+6*x+8),x, algorithm="giac")

[Out]

5/2*log(abs(x + 4)) + 1/2*log(abs(x + 2))

________________________________________________________________________________________

maple [A]  time = 0.06, size = 14, normalized size = 0.82 \begin {gather*} \frac {\ln \left (x +2\right )}{2}+\frac {5 \ln \left (x +4\right )}{2} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((3*x+7)/(x^2+6*x+8),x)

[Out]

1/2*ln(x+2)+5/2*ln(x+4)

________________________________________________________________________________________

maxima [A]  time = 0.45, size = 13, normalized size = 0.76 \begin {gather*} \frac {5}{2} \, \log \left (x + 4\right ) + \frac {1}{2} \, \log \left (x + 2\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((7+3*x)/(x^2+6*x+8),x, algorithm="maxima")

[Out]

5/2*log(x + 4) + 1/2*log(x + 2)

________________________________________________________________________________________

mupad [B]  time = 0.05, size = 13, normalized size = 0.76 \begin {gather*} \frac {\ln \left (x+2\right )}{2}+\frac {5\,\ln \left (x+4\right )}{2} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((3*x + 7)/(6*x + x^2 + 8),x)

[Out]

log(x + 2)/2 + (5*log(x + 4))/2

________________________________________________________________________________________

sympy [A]  time = 0.11, size = 14, normalized size = 0.82 \begin {gather*} \frac {\log {\left (x + 2 \right )}}{2} + \frac {5 \log {\left (x + 4 \right )}}{2} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((7+3*x)/(x**2+6*x+8),x)

[Out]

log(x + 2)/2 + 5*log(x + 4)/2

________________________________________________________________________________________